package me.a_littlesquid.origin.tasks;


import me.a_littlesquid.origin.Origin;
import org.bukkit.Bukkit;
import org.bukkit.entity.Player;
import org.bukkit.scheduler.BukkitRunnable;

import java.util.UUID;

public class cooldown extends BukkitRunnable {
    private UUID uuid;
    private Origin plugin;
    public cooldown(UUID uuid){
        this.uuid=uuid;
    }
    @Override
    public void run() {
        try {
            Thread.sleep(60000);
        } catch (InterruptedException e) {
            throw new RuntimeException(e);
        }
        Player player= Bukkit.getPlayer(uuid);
        plugin = Origin.getInstance();
        potion potion=new potion(player);
        potion.runTask(plugin);
    }
}
